Help IndexTable of Contents

Parameterizing Queries via URL

When loading up content directly via URL string, certain member and set selections can be passed through to the query engine for inclusion in the result set.

NOTE: This process of parameterizing the query through URL is similar to ProClarity, and offers the same outcomes.

The process of parameterizing queries similar across both Data Discovery and Story Board. However, Story Board requires the use of the Input Target function to direct the parameters within the dashboard.

URL for loading content directly

A typical URL string that can be used to load up a book directly from the URL is as follows:

http://my.pyramid.com/default.aspx?bookid=ca3f0114-2a9d-4635-989f-fa74be84e3ac|ispasFalse|report0399babf-ee42-4439-b60d-b08190a7bb7a|ws0|wsb0|isExportedFalse|isDisabledAnalyticsTrue

  • The page address is presented in orange
  • The URL detail for loading up a specific content item is presented in purple. This includes URL switches.

Appending parameters to this string, will then further adjust the underlying query when it is run by the engine.

Adding Parameters to a report URL: Data Discovery

First, append the expression marker to the string above:

|expr=

Next, append any members to the expression marker using this formulation:

<m> member 1's unique name here </m>........<m> member n's unique name here </m>

Last, append any sets of members to the expression marker using this formulation:

<s h=" hierarchy's unique name ">{ member 1's unique name here, ...... member n's unique name here } </s>

Note that:

  • The member and hierarchy unique names should follow the standard syntax in MDX
  • Instead of the unique name, you can use MDX functions that return members like "[dimension].[hierarchy].[member].CHILDREN"
  • Special characters included in the URL should be encoded to conform to URL encoding standards.
Adding Parameters to a dashboard URL: Story Board

Before using URL parameters for dashboards, users first need to use the 'input target' function in the slide designer to map the incoming parameters to the relevant query panels.

Next, append the input marker to the string above:

|inputs=

Next, append any members to the expression marker using this formulation. Importantly, each member node "<m>" needs to have a name attribute tag that matches the name of the input parameter created in the slide (in red below). In this case, the input target was called 'target1'.:

<m name="target1"> member 1's unique name here </m>........<m> member n's unique name here </m>

Last, append any sets of members to the expression marker using this formulation. Like members these also require the name attribute tag:

<s name="target2" h=" hierarchy's unique name ">{ member 1's unique name here, ...... member n's unique name here } </s>

Note that:

  • The member and hierarchy unique names should follow the standard syntax in MDX
  • Instead of the unique name, you can use MDX functions that return members like "[dimension].[hierarchy].[member].CHILDREN"
  • Special characters included in the URL should be encoded to conform to URL encoding standards.
Special Characters
  • Space can also be replaced with %20

  • Double quotation mark can also be replaced with %22

  • Ampersand (&) can also be replaced with %26

Handling of URL Parameters

  • If it’s a member and if the dimensions of the parameters DO NOT appear on the rows or columns, it will go into the WHERE section of the query.
  • If the dimension is parameterized using Pyramid’s internal parameter engine, the member/set will be used to populate the parameter field with the selections on the rows or the columns.
  • If it’s a member and if the dimensions of the parameters DO appear on the rows or columns (and its NOT parameterized by Pyramid), we will replace ALL selections for that dimension on that axis with the parameters chosen.

Home | Table of Contents | Index | User Community
Pyramid Analytics © 2011-2022